package com.info33.platform.business.app.entity;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.info33.platform.common.mvc.entity.BaseEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * app - 租户 - 用户角色关联
 *
 * @author admin
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class AppRoleUser extends BaseEntity {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "用户 id【app_tenant_user】")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long userId;

    @ApiModelProperty(value = "角色 id【app_tenant_role】")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long roleId;

    @ApiModelProperty(value = "是否有效：1/是、0/否")
    private Boolean valid;

    @ApiModelProperty(value = "是否是主要身份：1/是、0/否")
    private Boolean principal;

}